package com.sunlands.qdcy.deskmate.vo.feign;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;
import org.springframework.beans.BeanUtils;

import javax.persistence.Column;
import java.io.Serializable;
import java.util.Collections;
import java.util.Date;
import java.util.List;
import java.util.Objects;
import java.util.stream.Collectors;

/**
 * @author shixiaopeng
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
@DynamicUpdate
@DynamicInsert
public class VipUserVO implements Serializable {

    private static final long serialVersionUID = -5211975848079627189L;

    @ApiModelProperty(value = "id")
    private Long id;

    /**
     * 用户表tz_user的id
     */
    @ApiModelProperty(value = "用户表的id")
    private Long userId;

    /**
     * 过期日期
     */
    @ApiModelProperty(value = "过期日期")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date expireDate;

    /**
     *使用时长
     */
    @ApiModelProperty(value = "已使用时长,分钟")
    private Long useredTime;

    /**
     * 总时长
     */
    @ApiModelProperty(value = "总时长，分钟")
    private Long totalTime;

    /**
     * 状态：1有效，0无效
     */
    @ApiModelProperty(value = "状态：1有效，0无效")
    private Integer status;

    @ApiModelProperty(value = "更新时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @Column(insertable = false, updatable = false)
    Date updateTime;

    @ApiModelProperty(value ="创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @Column(insertable = false, updatable = false)
    Date createTime;


}
